var Schema = mongoose.Schema;

var iwantSchema = new Schema({

    user: {type: Schema.Types.ObjectId, ref: 'user'},
    type: Number,       //1,找玩伴; 2,干点啥;3,找老乡
    condition: String,
    content: [String],    //所想内容
    community: {type: Schema.Types.ObjectId, ref: 'community'},
    dateCreated: {type: Date, default: Date.now}

});

mongoose.model('user_i_want', iwantSchema,'user_i_want');